package webbrow.member.controller;

import java.sql.SQLException;
import java.util.List;

import javax.annotation.Resource;

import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.servlet.ModelAndView;

import webbrow.member.model.MemberService;
import webbrow.member.model.MemberVO;
@Controller
public class AdministratorController {
	@Resource(name = "memberServiceImpl")
	private MemberService memberService;
	
	// 관리자 권한 - 회원리스트 보기
	@RequestMapping("/memberList.inven")
	public ModelAndView getMemberList() throws SQLException {
		List<MemberVO> mvo = memberService.showMemberList();
		return new ModelAndView("admin/member_list.admin", "mvo", mvo);
	}
	// 관리자 권한 - 공지사항 글쓰기 폼으로 이동
	@RequestMapping("writeNoticeForm.inven")
	public String writeNoticeForm(){
		return "admin/write_notice.admin";
	}

}
